package com.weijian.demo1.entity;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Data
@Schema(description = "文档实体")
public class Document {
    @Schema(description = "文档ID", example = "1")
    private Long id;

    @Schema(description = "文档标题", example = "项目计划书")
    private String title;

    @Schema(description = "文档内容", example = "这是文档的内容...")
    private String content;

    @Schema(description = "团队ID", example = "1")
    private Long teamId;

    @Schema(description = "创建者ID", example = "1")
    private Long createdBy; // 创建者ID

    @Schema(description = "最后修改者ID", example = "2")
    private Long lastModifiedBy; // 最后修改者ID

    @Schema(description = "创建时间")
    private LocalDateTime createdAt;

    @Schema(description = "更新时间")
    private LocalDateTime updatedAt;

    @Schema(description = "乐观锁版本号", example = "1")
    private Integer version; // 乐观锁版本号
}
